/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package Blogic;

import Beans.BancoBean;
import Conexion.Conexion;
import Dao.BancoDAO;
import java.util.Vector;

/**
 *
 * @author orellana
 */
public class BancoBLogic {

    // Constructor
    public Vector execute(BancoBean bancoBean){
        // Variables locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).insertDatosBanco(bancoBean, conect);
        // Retornamos el valor
        return resultDatos;
}

public Vector getDatosBancos(BancoBean bancoBean){
        // Variables locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO().getDatosBancos(bancoBean, conect));
        // Retornamos el valor
        return resultDatos;
    }

    public Vector getDatosBanco(BancoBean bancoBean){
        // Variables locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO().getDatosBanco(bancoBean, conect));
        // Retornamos el valor
        return resultDatos;
    }

    public Vector getIdBanco(BancoBean bancoBean){
        // Variables Locales
       Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).getIdBanco(bancoBean, conect);
        // Retornamos el Valor
        return resultDatos;
    }

    public Vector deleteDatosBanco(BancoBean bancoBean){
        //Variables locales
        Vector resultDatos = new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO().deleteDatosBanco(bancoBean, conect));
        //Retornamos el valor
        return resultDatos;
    }

    //Modificacion de datos
    public Vector updateDatosBanco(BancoBean bancoBean){
        // Variables Locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).updateDatosBanco(bancoBean, conect);
        // Retornamos el Valor
        return resultDatos;
    }

     public Vector buscarDatosBancoActivo(BancoBean bancoBean){
        // Variables Locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).buscarDatosBancoActivo(bancoBean, conect);
        // Retornamos el Valor
        return resultDatos;
    }

     public Vector buscarDatosBancoCombo(BancoBean bancoBean){
        // Variables Locales
        Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).buscarDatosBancoCombo(bancoBean, conect);
        // Retornamos el Valor
        return resultDatos;
    }

      public Vector getIdBancoNombre(BancoBean bancoBean){
        // Variables Locales
       Vector resultDatos=new Vector();
        Conexion conect=new Conexion();
        resultDatos=(new BancoDAO()).getIdBancoNombre(bancoBean, conect);
        // Retornamos el Valor
        return resultDatos;
    }

}
